using System;
using System.IO;

namespace LS.Digitize
{
    public sealed class DecimalSerializer: PrimitiveSerializer<decimal>
    {
        public DecimalSerializer() : base()
        {
            
        }
        public override void WriteData(IWriter writer, decimal obj)
        {
            writer.WritePrimitive(obj);
        }

        public override decimal ReadData(IReader reader)
        {
            return reader.ReadDecimal();
        }
    }
}